// pages/liking/liking.js
const app=getApp()
Page({

    /**
     * 页面的初始数据
     */
    data: {

    },
    jumpPage:function(e){
        let bid=e.currentTarget.id;
        let uid=wx.getStorageSync('Uid')
        console.log(uid)
        wx.navigateTo({
            url:'/pages/me-homepage/me-homepage?Uid='+uid+'&Bid='+bid
        })
      },
    /**
     * 生命周期函数--监听页面加载
     */
    onLoad: function (options) {
        this.getRes()
    },
    getRes:function(){
        wx.request({
            url:`${app.globalData.url}/message/me-liking?Uid=`+wx.getStorageSync('Uid'),
            success:res=>{
                console.log(res.data);
                this.setData({
                    list:res.data
                })
            }
        })
    },
    onshow:function(){
        this.getRes()
    },
    changeDetail:function(e){
        let wid=e.currentTarget.id;
        console.log(this.data.Wid);
        wx.navigateTo({
            url:'/pages/com_detail/com_detail?Wid='+wid
        })
    }
})